﻿using Ledict.ConditionExtract.DAL;
using Ledict.ConditionExtract.Model;
using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Ledict.ConditionExtract.BLL
{
    public class XF_Grade_RelationBLL
    {
        XF_Grade_RelationDAL xgrDal = new XF_Grade_RelationDAL();

        /// <summary>
        /// 增加一条数据
        /// </summary>
        public bool Add(XF_Grade_RelationtModel model)
        {
            return xgrDal.Add(model);
        }

        /// <summary>
        /// 删除一条数据
        /// </summary>
        public bool Delete(string ccId)
        {
            return xgrDal.Delete(ccId);
        }

        /// <summary>
        /// 获取档次与主刑关系表数据
        /// </summary>
        /// <param name="ccid">节点信息</param>
        /// <returns></returns>
        public DataTable GetPunishmentGrade(string ccid)
        {
            return xgrDal.GetPunishmentGrade(ccid);
        }

        /// <summary>
        /// 修改，通过GR_ID
        /// </summary>
        public bool UpdateName(XF_Grade_RelationtModel model)
        {
            return xgrDal.UpdateName(model);
        }
    }
}
